import java.io.Serializable;

public class Course implements Serializable {
    private static final long serialVersionUID = 1L;
    private String courseId;   // 课程编号
    private String courseName; // 课程名称
    private double credit;     // 学分

    public Course(String courseId, String courseName, double credit) {
        this.courseId = courseId;
        this.courseName = courseName;
        this.credit = credit;
    }

    // Getter & Setter
    public String getCourseId() { return courseId; }
    public void setCourseId(String courseId) { this.courseId = courseId; }
    public String getCourseName() { return courseName; }
    public void setCourseName(String courseName) { this.courseName = courseName; }
    public double getCredit() { return credit; }
    public void setCredit(double credit) { this.credit = credit; }

    @Override
    public String toString() {
        return "Course{courseId='" + courseId + "', courseName='" + courseName + "', credit=" + credit + "}";
    }
}